﻿/*
 * Jonathan
 * Created by: Jonathan Montiverdi
 * Date: 07/25/2012
 * License: http://jonathan.codeplex.com/license
 */
using Monti.MVVM;

namespace Jonathan.Data
{
   /// <summary>
   /// Description of CheckedListItem.
   /// </summary>
   public class CheckedListItem : ViewModelBase
   {
      private bool m_IsChecked;
      private string m_Name;
      private object m_Tag;
      
      /// <summary>
      /// Gets or Sets the name of the item.
      /// </summary>
      public string Name
      {
         get { return this.m_Name; }
         set
         {
            if (this.m_Name != value)
            {
               this.m_Name = value;
               this.RaisePropertyChanged ("Name");
            }
         }
      }
      
      /// <summary>
      /// Gets or Sets if the item is checked or not.
      /// </summary>
      public bool IsChecked
      {
         get { return this.m_IsChecked; }
         set
         {
            if (this.m_IsChecked != value)
            {
               this.m_IsChecked = value;
               this.RaisePropertyChanged ("IsChecked");
            }
         }
      }
      
      /// <summary>
      /// Gets or Sets the tag of the item.
      /// </summary>
      public object Tag
      {
         get { return this.m_Tag; }
         set
         {
            if (this.m_Tag != value)
            {
               this.m_Tag = value;
               this.RaisePropertyChanged ("Tag");
            }
         }
      }
   }
}
